﻿using System;
using System.Collections.Generic;
 
using System.Text;

namespace GGSharp.Packets
{
    public class ConferenceMessagePacket : MessagePacket
    {
        public ConferenceMessagePacket() : base() {  }
        public ConferenceMessagePacket(string message) : base(0, message) { }

        protected List<int> _recipients = new List<int>();

        public List<int> Recipients
        {
            get { return _recipients; }
        }

        public override void Read(System.IO.BinaryReader reader)
        {
            base.Read(reader);
            throw new NotImplementedException();
        }

        public override void Write(System.IO.BinaryWriter writer)
        {
            this.Length += 5 + Recipients.Count * 4;
            base.Write(writer);

            writer.Write((byte)1);
            writer.Write((int)Recipients.Count);
            for (int i = 0; i < Recipients.Count; i++)
                writer.Write(_recipients[i]);
        }
    }
}
